// import Cookies from 'js-cookie'
// import { Decrypt,Encrypt } from '@/utils/aesUtils'

const TokenKey = 'yidianyun_token'
const ImgSrcKey = 'yidianyun_imgSrc'
const uerInfoKey = 'yidianyun_userInfo'

export function getToken() {
  return localStorage.getItem(TokenKey)
}

export function setToken(token) {
  return localStorage.setItem(TokenKey, token)
}

export function removeToken() {
  return localStorage.removeItem(TokenKey)
}
export function getImgSrc() {
  return localStorage.getItem(ImgSrcKey)
}

export function setImgSrc(ImgSrc) {
  return localStorage.setItem(ImgSrcKey, ImgSrc)
}

export function removeImgSrc() {
  return localStorage.removeItem(ImgSrcKey)
}

export function getUserInfos() {
  return JSON.parse(localStorage.getItem(uerInfoKey))
}

export function setUserInfo(userInfo) {
  return localStorage.setItem(uerInfoKey, JSON.stringify(userInfo))
}

export function removeUserInfo() {
  return localStorage.removeItem(uerInfoKey)
}
